Integrand size = 25, antiderivative size = 254 \[ \int \frac {(a+b \sec (e+f x))^3}{(c+d \sec (e+f x))^3} \, dx=\frac {a^3 x}{c^3}-\frac {(b c-a d) \left (2 a b c d \left (4 c^2-d^2\right )-b^2 c^2 \left (c^2+2 d^2\right )-a^2 \left (6 c^4-5 c^2 d^2+2 d^4\right )\right ) \text {arctanh}\left (\frac {\sqrt {c-d} \tan \left (\frac {1}{2} (e+f x)\right )}{\sqrt {c+d}}\right )}{c^3 (c-d)^{5/2} (c+d)^{5/2} f}+\frac {(b c-a d)^2 (b+a \cos (e+f x)) \sin (e+f x)}{2 c \left (c^2-d^2\right ) f (d+c \cos (e+f x))^2}+\frac {(b c-a d)^2 \left (5 a c^2-3 b c d-2 a d^2\right ) \sin (e+f x)}{2 c^2 \left (c^2-d^2\right )^2 f (d+c \cos (e+f x))} \]
a^3*x/c^3-(-a*d+b*c)*(2*a*b*c*d*(4*c^2-d^2)-b^2*c^2*(c^2+2*d^2)-a^2*(6*c^4 -5*c^2*d^2+2*d^4))*arctanh((c-d)^(1/2)*tan(1/2*f*x+1/2*e)/(c+d)^(1/2))/c^3 /(c-d)^(5/2)/(c+d)^(5/2)/f+1/2*(-a*d+b*c)^2*(b+a*cos(f*x+e))*sin(f*x+e)/c/ (c^2-d^2)/f/(d+c*cos(f*x+e))^2+1/2*(-a*d+b*c)^2*(5*a*c^2-2*a*d^2-3*b*c*d)* sin(f*x+e)/c^2/(c^2-d^2)^2/f/(d+c*cos(f*x+e))
Leaf count is larger than twice the leaf count of optimal. \(517\) vs. \(2(254)=508\).
Time = 2.25 (sec) , antiderivative size = 517, normalized size of antiderivative = 2.04 \[ \int \frac {(a+b \sec (e+f x))^3}{(c+d \sec (e+f x))^3} \, dx=\frac {-\frac {4 \left (-9 a b^2 c^4 d+3 a^2 b c^3 \left (2 c^2+d^2\right )+b^3 c^3 \left (c^2+2 d^2\right )+a^3 \left (-6 c^4 d+5 c^2 d^3-2 d^5\right )\right ) \text {arctanh}\left (\frac {(-c+d) \tan \left (\frac {1}{2} (e+f x)\right )}{\sqrt {c^2-d^2}}\right )}{\left (c^2-d^2\right )^{5/2}}+\frac {2 a^3 c^6 e-6 a^3 c^2 d^4 e+4 a^3 d^6 e+2 a^3 c^6 f x-6 a^3 c^2 d^4 f x+4 a^3 d^6 f x+8 a^3 c d \left (c^2-d^2\right )^2 (e+f x) \cos (e+f x)+2 a^3 \left (c^3-c d^2\right )^2 (e+f x) \cos (2 (e+f x))+2 b^3 c^6 \sin (e+f x)+6 a b^2 c^5 d \sin (e+f x)-18 a^2 b c^4 d^2 \sin (e+f x)-8 b^3 c^4 d^2 \sin (e+f x)+10 a^3 c^3 d^3 \sin (e+f x)+12 a b^2 c^3 d^3 \sin (e+f x)-4 a^3 c d^5 \sin (e+f x)+6 a b^2 c^6 \sin (2 (e+f x))-12 a^2 b c^5 d \sin (2 (e+f x))-3 b^3 c^5 d \sin (2 (e+f x))+6 a^3 c^4 d^2 \sin (2 (e+f x))+3 a b^2 c^4 d^2 \sin (2 (e+f x))+3 a^2 b c^3 d^3 \sin (2 (e+f x))-3 a^3 c^2 d^4 \sin (2 (e+f x))}{\left (c^2-d^2\right )^2 (d+c \cos (e+f x))^2}}{4 c^3 f} \]
((-4*(-9*a*b^2*c^4*d + 3*a^2*b*c^3*(2*c^2 + d^2) + b^3*c^3*(c^2 + 2*d^2) + a^3*(-6*c^4*d + 5*c^2*d^3 - 2*d^5))*ArcTanh[((-c + d)*Tan[(e + f*x)/2])/S qrt[c^2 - d^2]])/(c^2 - d^2)^(5/2) + (2*a^3*c^6*e - 6*a^3*c^2*d^4*e + 4*a^ 3*d^6*e + 2*a^3*c^6*f*x - 6*a^3*c^2*d^4*f*x + 4*a^3*d^6*f*x + 8*a^3*c*d*(c ^2 - d^2)^2*(e + f*x)*Cos[e + f*x] + 2*a^3*(c^3 - c*d^2)^2*(e + f*x)*Cos[2 *(e + f*x)] + 2*b^3*c^6*Sin[e + f*x] + 6*a*b^2*c^5*d*Sin[e + f*x] - 18*a^2 *b*c^4*d^2*Sin[e + f*x] - 8*b^3*c^4*d^2*Sin[e + f*x] + 10*a^3*c^3*d^3*Sin[ e + f*x] + 12*a*b^2*c^3*d^3*Sin[e + f*x] - 4*a^3*c*d^5*Sin[e + f*x] + 6*a* b^2*c^6*Sin[2*(e + f*x)] - 12*a^2*b*c^5*d*Sin[2*(e + f*x)] - 3*b^3*c^5*d*S in[2*(e + f*x)] + 6*a^3*c^4*d^2*Sin[2*(e + f*x)] + 3*a*b^2*c^4*d^2*Sin[2*( e + f*x)] + 3*a^2*b*c^3*d^3*Sin[2*(e + f*x)] - 3*a^3*c^2*d^4*Sin[2*(e + f* x)])/((c^2 - d^2)^2*(d + c*Cos[e + f*x])^2))/(4*c^3*f)
Time = 1.27 (sec) , antiderivative size = 302, normalized size of antiderivative = 1.19, number of steps used = 13, number of rules used = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.480, Rules used = {3042, 4429, 3042, 3271, 3042, 3500, 25, 3042, 3214, 3042, 3138, 221}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {(a+b \sec (e+f x))^3}{(c+d \sec (e+f x))^3} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\left (a+b \csc \left (e+f x+\frac {\pi }{2}\right )\right )^3}{\left (c+d \csc \left (e+f x+\frac {\pi }{2}\right )\right )^3}dx\) |
\(\Big \downarrow \) 4429 |
\(\displaystyle \int \frac {(a \cos (e+f x)+b)^3}{(c \cos (e+f x)+d)^3}dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {\left (a \sin \left (e+f x+\frac {\pi }{2}\right )+b\right )^3}{\left (c \sin \left (e+f x+\frac {\pi }{2}\right )+d\right )^3}dx\) |
\(\Big \downarrow \) 3271 |
\(\displaystyle \frac {\int \frac {d^2 a^3+2 \left (c^2-d^2\right ) \cos ^2(e+f x) a^3-4 b c d a^2+5 b^2 c^2 a-2 b^3 c d+\left (-2 c d a^3+b \left (6 c^2-d^2\right ) a^2-4 b^2 c d a+b^3 c^2\right ) \cos (e+f x)}{(d+c \cos (e+f x))^2}dx}{2 c \left (c^2-d^2\right )}+\frac {(b c-a d)^2 \sin (e+f x) (a \cos (e+f x)+b)}{2 c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)^2}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int \frac {d^2 a^3+2 \left (c^2-d^2\right ) \sin \left (e+f x+\frac {\pi }{2}\right )^2 a^3-4 b c d a^2+5 b^2 c^2 a-2 b^3 c d+\left (-2 c d a^3+b \left (6 c^2-d^2\right ) a^2-4 b^2 c d a+b^3 c^2\right ) \sin \left (e+f x+\frac {\pi }{2}\right )}{\left (d+c \sin \left (e+f x+\frac {\pi }{2}\right )\right )^2}dx}{2 c \left (c^2-d^2\right )}+\frac {(b c-a d)^2 \sin (e+f x) (a \cos (e+f x)+b)}{2 c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)^2}\) |
\(\Big \downarrow \) 3500 |
\(\displaystyle \frac {\frac {\int -\frac {c \left (\left (4 c^2 d-d^3\right ) a^3-3 b c \left (2 c^2+d^2\right ) a^2+9 b^2 c^2 d a-b^3 c \left (c^2+2 d^2\right )\right )-2 a^3 \left (c^2-d^2\right )^2 \cos (e+f x)}{d+c \cos (e+f x)}dx}{c \left (c^2-d^2\right )}+\frac {\left (5 a c^2-2 a d^2-3 b c d\right ) (b c-a d)^2 \sin (e+f x)}{c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)}}{2 c \left (c^2-d^2\right )}+\frac {(b c-a d)^2 \sin (e+f x) (a \cos (e+f x)+b)}{2 c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)^2}\) |
\(\Big \downarrow \) 25 |
\(\displaystyle \frac {\frac {(b c-a d)^2 \left (5 a c^2-2 a d^2-3 b c d\right ) \sin (e+f x)}{c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)}-\frac {\int \frac {c \left (\left (4 c^2 d-d^3\right ) a^3-3 b c \left (2 c^2+d^2\right ) a^2+9 b^2 c^2 d a-b^3 c \left (c^2+2 d^2\right )\right )-2 a^3 \left (c^2-d^2\right )^2 \cos (e+f x)}{d+c \cos (e+f x)}dx}{c \left (c^2-d^2\right )}}{2 c \left (c^2-d^2\right )}+\frac {(b c-a d)^2 \sin (e+f x) (a \cos (e+f x)+b)}{2 c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)^2}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\frac {(b c-a d)^2 \left (5 a c^2-2 a d^2-3 b c d\right ) \sin (e+f x)}{c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)}-\frac {\int \frac {c \left (\left (4 c^2 d-d^3\right ) a^3-3 b c \left (2 c^2+d^2\right ) a^2+9 b^2 c^2 d a-b^3 c \left (c^2+2 d^2\right )\right )-2 a^3 \left (c^2-d^2\right )^2 \sin \left (e+f x+\frac {\pi }{2}\right )}{d+c \sin \left (e+f x+\frac {\pi }{2}\right )}dx}{c \left (c^2-d^2\right )}}{2 c \left (c^2-d^2\right )}+\frac {(b c-a d)^2 \sin (e+f x) (a \cos (e+f x)+b)}{2 c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)^2}\) |
\(\Big \downarrow \) 3214 |
\(\displaystyle \frac {\frac {(b c-a d)^2 \left (5 a c^2-2 a d^2-3 b c d\right ) \sin (e+f x)}{c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)}-\frac {\frac {\left (a^3 \left (6 c^4 d-5 c^2 d^3+2 d^5\right )-3 a^2 b c^3 \left (2 c^2+d^2\right )+9 a b^2 c^4 d-b^3 c^3 \left (c^2+2 d^2\right )\right ) \int \frac {1}{d+c \cos (e+f x)}dx}{c}-\frac {2 a^3 x \left (c^2-d^2\right )^2}{c}}{c \left (c^2-d^2\right )}}{2 c \left (c^2-d^2\right )}+\frac {(b c-a d)^2 \sin (e+f x) (a \cos (e+f x)+b)}{2 c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)^2}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\frac {(b c-a d)^2 \left (5 a c^2-2 a d^2-3 b c d\right ) \sin (e+f x)}{c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)}-\frac {\frac {\left (a^3 \left (6 c^4 d-5 c^2 d^3+2 d^5\right )-3 a^2 b c^3 \left (2 c^2+d^2\right )+9 a b^2 c^4 d-b^3 c^3 \left (c^2+2 d^2\right )\right ) \int \frac {1}{d+c \sin \left (e+f x+\frac {\pi }{2}\right )}dx}{c}-\frac {2 a^3 x \left (c^2-d^2\right )^2}{c}}{c \left (c^2-d^2\right )}}{2 c \left (c^2-d^2\right )}+\frac {(b c-a d)^2 \sin (e+f x) (a \cos (e+f x)+b)}{2 c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)^2}\) |
\(\Big \downarrow \) 3138 |
\(\displaystyle \frac {\frac {(b c-a d)^2 \left (5 a c^2-2 a d^2-3 b c d\right ) \sin (e+f x)}{c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)}-\frac {\frac {2 \left (a^3 \left (6 c^4 d-5 c^2 d^3+2 d^5\right )-3 a^2 b c^3 \left (2 c^2+d^2\right )+9 a b^2 c^4 d-b^3 c^3 \left (c^2+2 d^2\right )\right ) \int \frac {1}{-\left ((c-d) \tan ^2\left (\frac {1}{2} (e+f x)\right )\right )+c+d}d\tan \left (\frac {1}{2} (e+f x)\right )}{c f}-\frac {2 a^3 x \left (c^2-d^2\right )^2}{c}}{c \left (c^2-d^2\right )}}{2 c \left (c^2-d^2\right )}+\frac {(b c-a d)^2 \sin (e+f x) (a \cos (e+f x)+b)}{2 c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)^2}\) |
\(\Big \downarrow \) 221 |
\(\displaystyle \frac {\frac {(b c-a d)^2 \left (5 a c^2-2 a d^2-3 b c d\right ) \sin (e+f x)}{c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)}-\frac {\frac {2 \left (a^3 \left (6 c^4 d-5 c^2 d^3+2 d^5\right )-3 a^2 b c^3 \left (2 c^2+d^2\right )+9 a b^2 c^4 d-b^3 c^3 \left (c^2+2 d^2\right )\right ) \text {arctanh}\left (\frac {\sqrt {c-d} \tan \left (\frac {1}{2} (e+f x)\right )}{\sqrt {c+d}}\right )}{c f \sqrt {c-d} \sqrt {c+d}}-\frac {2 a^3 x \left (c^2-d^2\right )^2}{c}}{c \left (c^2-d^2\right )}}{2 c \left (c^2-d^2\right )}+\frac {(b c-a d)^2 \sin (e+f x) (a \cos (e+f x)+b)}{2 c f \left (c^2-d^2\right ) (c \cos (e+f x)+d)^2}\) |
((b*c - a*d)^2*(b + a*Cos[e + f*x])*Sin[e + f*x])/(2*c*(c^2 - d^2)*f*(d + c*Cos[e + f*x])^2) + (-(((-2*a^3*(c^2 - d^2)^2*x)/c + (2*(9*a*b^2*c^4*d - 3*a^2*b*c^3*(2*c^2 + d^2) - b^3*c^3*(c^2 + 2*d^2) + a^3*(6*c^4*d - 5*c^2*d ^3 + 2*d^5))*ArcTanh[(Sqrt[c - d]*Tan[(e + f*x)/2])/Sqrt[c + d]])/(c*Sqrt[ c - d]*Sqrt[c + d]*f))/(c*(c^2 - d^2))) + ((b*c - a*d)^2*(5*a*c^2 - 3*b*c* d - 2*a*d^2)*Sin[e + f*x])/(c*(c^2 - d^2)*f*(d + c*Cos[e + f*x])))/(2*c*(c ^2 - d^2))
3.2.95.3.1 Defintions of rubi rules used
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[-a/b, 2]/a)*ArcTanh[x /Rt[-a/b, 2]], x] /; FreeQ[{a, b}, x] && NegQ[a/b]
Int[((a_) + (b_.)*sin[Pi/2 + (c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> With[{ e = FreeFactors[Tan[(c + d*x)/2], x]}, Simp[2*(e/d) Subst[Int[1/(a + b + (a - b)*e^2*x^2), x], x, Tan[(c + d*x)/2]/e], x]] /; FreeQ[{a, b, c, d}, x] && NeQ[a^2 - b^2, 0]
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])/((c_.) + (d_.)*sin[(e_.) + (f_. )*(x_)]), x_Symbol] :> Simp[b*(x/d), x] - Simp[(b*c - a*d)/d Int[1/(c + d *Sin[e + f*x]), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0]
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((c_.) + (d_.)*sin[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Simp[(-(b^2*c^2 - 2*a*b*c*d + a^2*d^2))*Co s[e + f*x]*(a + b*Sin[e + f*x])^(m - 2)*((c + d*Sin[e + f*x])^(n + 1)/(d*f* (n + 1)*(c^2 - d^2))), x] + Simp[1/(d*(n + 1)*(c^2 - d^2)) Int[(a + b*Sin [e + f*x])^(m - 3)*(c + d*Sin[e + f*x])^(n + 1)*Simp[b*(m - 2)*(b*c - a*d)^ 2 + a*d*(n + 1)*(c*(a^2 + b^2) - 2*a*b*d) + (b*(n + 1)*(a*b*c^2 + c*d*(a^2 + b^2) - 3*a*b*d^2) - a*(n + 2)*(b*c - a*d)^2)*Sin[e + f*x] + b*(b^2*(c^2 - d^2) - m*(b*c - a*d)^2 + d*n*(2*a*b*c - d*(a^2 + b^2)))*Sin[e + f*x]^2, x] , x], x] /; FreeQ[{a, b, c, d, e, f}, x] && NeQ[b*c - a*d, 0] && NeQ[a^2 - b^2, 0] && NeQ[c^2 - d^2, 0] && GtQ[m, 2] && LtQ[n, -1] && (IntegerQ[m] || IntegersQ[2*m, 2*n])
Int[((a_.) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((A_.) + (B_.)*sin[(e_.) + (f_.)*(x_)] + (C_.)*sin[(e_.) + (f_.)*(x_)]^2), x_Symbol] :> Simp[(-(A*b^2 - a*b*B + a^2*C))*Cos[e + f*x]*((a + b*Sin[e + f*x])^(m + 1)/(b*f*(m + 1)* (a^2 - b^2))), x] + Simp[1/(b*(m + 1)*(a^2 - b^2)) Int[(a + b*Sin[e + f*x ])^(m + 1)*Simp[b*(a*A - b*B + a*C)*(m + 1) - (A*b^2 - a*b*B + a^2*C + b*(A *b - a*B + b*C)*(m + 1))*Sin[e + f*x], x], x], x] /; FreeQ[{a, b, e, f, A, B, C}, x] && LtQ[m, -1] && NeQ[a^2 - b^2, 0]
Int[(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_)*(csc[(e_.) + (f_.)*(x_)]*(d _.) + (c_))^(n_), x_Symbol] :> Int[(b + a*Sin[e + f*x])^m*((d + c*Sin[e + f *x])^n/Sin[e + f*x]^(m + n)), x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && N eQ[b*c - a*d, 0] && IntegerQ[m] && IntegerQ[n] && LeQ[-2, m + n, 0]
Time = 1.19 (sec) , antiderivative size = 458, normalized size of antiderivative = 1.80
method | result | size |
derivativedivides | \(\frac {\frac {2 a^{3} \arctan \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{c^{3}}+\frac {\frac {2 \left (-\frac {\left (6 a^{3} c^{2} d^{2}+a^{3} d^{3} c -2 a^{3} d^{4}-12 a^{2} b \,c^{3} d -3 a^{2} b \,c^{2} d^{2}+6 a \,b^{2} c^{4}+3 a \,b^{2} c^{3} d +6 a \,b^{2} c^{2} d^{2}-b^{3} c^{4}-4 b^{3} c^{3} d \right ) c \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{3}}{2 \left (c -d \right ) \left (c^{2}+2 c d +d^{2}\right )}+\frac {c \left (6 a^{3} c^{2} d^{2}-a^{3} d^{3} c -2 a^{3} d^{4}-12 a^{2} b \,c^{3} d +3 a^{2} b \,c^{2} d^{2}+6 a \,b^{2} c^{4}-3 a \,b^{2} c^{3} d +6 a \,b^{2} c^{2} d^{2}+b^{3} c^{4}-4 b^{3} c^{3} d \right ) \tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{2 \left (c +d \right ) \left (c -d \right )^{2}}\right )}{\left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2} c -\tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2} d -c -d \right )^{2}}-\frac {\left (6 a^{3} c^{4} d -5 a^{3} c^{2} d^{3}+2 a^{3} d^{5}-6 a^{2} b \,c^{5}-3 a^{2} b \,c^{3} d^{2}+9 a \,b^{2} c^{4} d -b^{3} c^{5}-2 b^{3} c^{3} d^{2}\right ) \operatorname {arctanh}\left (\frac {\left (c -d \right ) \tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{\sqrt {\left (c +d \right ) \left (c -d \right )}}\right )}{\left (c^{4}-2 c^{2} d^{2}+d^{4}\right ) \sqrt {\left (c +d \right ) \left (c -d \right )}}}{c^{3}}}{f}\) | \(458\) |
default | \(\frac {\frac {2 a^{3} \arctan \left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{c^{3}}+\frac {\frac {2 \left (-\frac {\left (6 a^{3} c^{2} d^{2}+a^{3} d^{3} c -2 a^{3} d^{4}-12 a^{2} b \,c^{3} d -3 a^{2} b \,c^{2} d^{2}+6 a \,b^{2} c^{4}+3 a \,b^{2} c^{3} d +6 a \,b^{2} c^{2} d^{2}-b^{3} c^{4}-4 b^{3} c^{3} d \right ) c \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{3}}{2 \left (c -d \right ) \left (c^{2}+2 c d +d^{2}\right )}+\frac {c \left (6 a^{3} c^{2} d^{2}-a^{3} d^{3} c -2 a^{3} d^{4}-12 a^{2} b \,c^{3} d +3 a^{2} b \,c^{2} d^{2}+6 a \,b^{2} c^{4}-3 a \,b^{2} c^{3} d +6 a \,b^{2} c^{2} d^{2}+b^{3} c^{4}-4 b^{3} c^{3} d \right ) \tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{2 \left (c +d \right ) \left (c -d \right )^{2}}\right )}{\left (\tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2} c -\tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{2} d -c -d \right )^{2}}-\frac {\left (6 a^{3} c^{4} d -5 a^{3} c^{2} d^{3}+2 a^{3} d^{5}-6 a^{2} b \,c^{5}-3 a^{2} b \,c^{3} d^{2}+9 a \,b^{2} c^{4} d -b^{3} c^{5}-2 b^{3} c^{3} d^{2}\right ) \operatorname {arctanh}\left (\frac {\left (c -d \right ) \tan \left (\frac {f x}{2}+\frac {e}{2}\right )}{\sqrt {\left (c +d \right ) \left (c -d \right )}}\right )}{\left (c^{4}-2 c^{2} d^{2}+d^{4}\right ) \sqrt {\left (c +d \right ) \left (c -d \right )}}}{c^{3}}}{f}\) | \(458\) |
risch | \(\text {Expression too large to display}\) | \(2042\) |
1/f*(2*a^3/c^3*arctan(tan(1/2*f*x+1/2*e))+2/c^3*((-1/2*(6*a^3*c^2*d^2+a^3* c*d^3-2*a^3*d^4-12*a^2*b*c^3*d-3*a^2*b*c^2*d^2+6*a*b^2*c^4+3*a*b^2*c^3*d+6 *a*b^2*c^2*d^2-b^3*c^4-4*b^3*c^3*d)*c/(c-d)/(c^2+2*c*d+d^2)*tan(1/2*f*x+1/ 2*e)^3+1/2*c*(6*a^3*c^2*d^2-a^3*c*d^3-2*a^3*d^4-12*a^2*b*c^3*d+3*a^2*b*c^2 *d^2+6*a*b^2*c^4-3*a*b^2*c^3*d+6*a*b^2*c^2*d^2+b^3*c^4-4*b^3*c^3*d)/(c+d)/ (c-d)^2*tan(1/2*f*x+1/2*e))/(tan(1/2*f*x+1/2*e)^2*c-tan(1/2*f*x+1/2*e)^2*d -c-d)^2-1/2*(6*a^3*c^4*d-5*a^3*c^2*d^3+2*a^3*d^5-6*a^2*b*c^5-3*a^2*b*c^3*d ^2+9*a*b^2*c^4*d-b^3*c^5-2*b^3*c^3*d^2)/(c^4-2*c^2*d^2+d^4)/((c+d)*(c-d))^ (1/2)*arctanh((c-d)*tan(1/2*f*x+1/2*e)/((c+d)*(c-d))^(1/2))))
Leaf count of result is larger than twice the leaf count of optimal. 785 vs. \(2 (238) = 476\).
Time = 0.40 (sec) , antiderivative size = 1629, normalized size of antiderivative = 6.41 \[ \int \frac {(a+b \sec (e+f x))^3}{(c+d \sec (e+f x))^3} \, dx=\text {Too large to display} \]
[1/4*(4*(a^3*c^8 - 3*a^3*c^6*d^2 + 3*a^3*c^4*d^4 - a^3*c^2*d^6)*f*x*cos(f* x + e)^2 + 8*(a^3*c^7*d - 3*a^3*c^5*d^3 + 3*a^3*c^3*d^5 - a^3*c*d^7)*f*x*c os(f*x + e) + 4*(a^3*c^6*d^2 - 3*a^3*c^4*d^4 + 3*a^3*c^2*d^6 - a^3*d^8)*f* x - (5*a^3*c^2*d^5 - 2*a^3*d^7 + (6*a^2*b + b^3)*c^5*d^2 - 3*(2*a^3 + 3*a* b^2)*c^4*d^3 + (3*a^2*b + 2*b^3)*c^3*d^4 + (5*a^3*c^4*d^3 - 2*a^3*c^2*d^5 + (6*a^2*b + b^3)*c^7 - 3*(2*a^3 + 3*a*b^2)*c^6*d + (3*a^2*b + 2*b^3)*c^5* d^2)*cos(f*x + e)^2 + 2*(5*a^3*c^3*d^4 - 2*a^3*c*d^6 + (6*a^2*b + b^3)*c^6 *d - 3*(2*a^3 + 3*a*b^2)*c^5*d^2 + (3*a^2*b + 2*b^3)*c^4*d^3)*cos(f*x + e) )*sqrt(c^2 - d^2)*log((2*c*d*cos(f*x + e) - (c^2 - 2*d^2)*cos(f*x + e)^2 - 2*sqrt(c^2 - d^2)*(d*cos(f*x + e) + c)*sin(f*x + e) + 2*c^2 - d^2)/(c^2*c os(f*x + e)^2 + 2*c*d*cos(f*x + e) + d^2)) + 2*(b^3*c^8 + 3*a*b^2*c^7*d + 2*a^3*c*d^7 - (9*a^2*b + 5*b^3)*c^6*d^2 + (5*a^3 + 3*a*b^2)*c^5*d^3 + (9*a ^2*b + 4*b^3)*c^4*d^4 - (7*a^3 + 6*a*b^2)*c^3*d^5 + 3*(2*a*b^2*c^8 - a^2*b *c^3*d^5 + a^3*c^2*d^6 - (4*a^2*b + b^3)*c^7*d + (2*a^3 - a*b^2)*c^6*d^2 + (5*a^2*b + b^3)*c^5*d^3 - (3*a^3 + a*b^2)*c^4*d^4)*cos(f*x + e))*sin(f*x + e))/((c^11 - 3*c^9*d^2 + 3*c^7*d^4 - c^5*d^6)*f*cos(f*x + e)^2 + 2*(c^10 *d - 3*c^8*d^3 + 3*c^6*d^5 - c^4*d^7)*f*cos(f*x + e) + (c^9*d^2 - 3*c^7*d^ 4 + 3*c^5*d^6 - c^3*d^8)*f), 1/2*(2*(a^3*c^8 - 3*a^3*c^6*d^2 + 3*a^3*c^4*d ^4 - a^3*c^2*d^6)*f*x*cos(f*x + e)^2 + 4*(a^3*c^7*d - 3*a^3*c^5*d^3 + 3*a^ 3*c^3*d^5 - a^3*c*d^7)*f*x*cos(f*x + e) + 2*(a^3*c^6*d^2 - 3*a^3*c^4*d^...
\[ \int \frac {(a+b \sec (e+f x))^3}{(c+d \sec (e+f x))^3} \, dx=\int \frac {\left (a + b \sec {\left (e + f x \right )}\right )^{3}}{\left (c + d \sec {\left (e + f x \right )}\right )^{3}}\, dx \]
Exception generated. \[ \int \frac {(a+b \sec (e+f x))^3}{(c+d \sec (e+f x))^3} \, dx=\text {Exception raised: ValueError} \]
Exception raised: ValueError >> Computation failed since Maxima requested additional constraints; using the 'assume' command before evaluation *may* help (example of legal syntax is 'assume(4*c^2-4*d^2>0)', see `assume?` f or more de
Leaf count of result is larger than twice the leaf count of optimal. 818 vs. \(2 (238) = 476\).
Time = 0.41 (sec) , antiderivative size = 818, normalized size of antiderivative = 3.22 \[ \int \frac {(a+b \sec (e+f x))^3}{(c+d \sec (e+f x))^3} \, dx=\text {Too large to display} \]
((f*x + e)*a^3/c^3 + (6*a^2*b*c^5 + b^3*c^5 - 6*a^3*c^4*d - 9*a*b^2*c^4*d + 3*a^2*b*c^3*d^2 + 2*b^3*c^3*d^2 + 5*a^3*c^2*d^3 - 2*a^3*d^5)*(pi*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*x + 1/2*e) - 6*a*b^2*c^2*d^3*tan(1/2*f*x + 1/2*e) + 3*a^3*c*d^4*tan(1/2*f*x + 1/2*e) + 2*a^3*d^5*tan(1/2*f*x + 1/2*e))/((c^6 - 2*c^4*d^2 + c^2*d^4)*(c*tan(1/2*f *x + 1/2*e)^2 - d*tan(1/2*f*x + 1/2*e)^2 - c - d)^2))/f
Time = 27.04 (sec) , antiderivative size = 10759, normalized size of antiderivative = 42.36 \[ \int \frac {(a+b \sec (e+f x))^3}{(c+d \sec (e+f x))^3} \, dx=\text {Too large to display} \]
(atan(((((8*tan(e/2 + (f*x)/2)*(4*a^6*c^10 + 8*a^6*d^10 + b^6*c^10 - 8*a^6 *c*d^9 - 8*a^6*c^9*d + 12*a^2*b^4*c^10 + 36*a^4*b^2*c^10 - 32*a^6*c^2*d^8 + 32*a^6*c^3*d^7 + 57*a^6*c^4*d^6 - 48*a^6*c^5*d^5 - 52*a^6*c^6*d^4 + 32*a ^6*c^7*d^3 + 24*a^6*c^8*d^2 + 4*b^6*c^6*d^4 + 4*b^6*c^8*d^2 - 36*a*b^5*c^7 *d^3 - 120*a^3*b^3*c^9*d - 12*a^5*b*c^3*d^7 + 6*a^5*b*c^5*d^5 + 24*a^5*b*c ^7*d^3 + 12*a^2*b^4*c^6*d^4 + 111*a^2*b^4*c^8*d^2 - 8*a^3*b^3*c^3*d^7 + 16 *a^3*b^3*c^5*d^5 - 68*a^3*b^3*c^7*d^3 + 36*a^4*b^2*c^4*d^6 - 81*a^4*b^2*c^ 6*d^4 + 144*a^4*b^2*c^8*d^2 - 18*a*b^5*c^9*d - 72*a^5*b*c^9*d))/(c^10*d + c^11 - c^4*d^7 - c^5*d^6 + 3*c^6*d^5 + 3*c^7*d^4 - 3*c^8*d^3 - 3*c^9*d^2) + ((a*d - b*c)*((8*(4*a^3*c^15 + 2*b^3*c^15 + 12*a^2*b*c^15 - 12*a^3*c^14* d - 2*b^3*c^14*d - 4*a^3*c^6*d^9 + 2*a^3*c^7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